﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Services;
using System.Web.Services.Protocols;
using RecruitStudents.Utility;

namespace RecruitStudents.Client.WS
{
    /// <summary>
    /// SecretaryService 的摘要说明
    /// </summary>
    [WebService(Namespace = "http://tempuri.org/")]
    [WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
    [System.ComponentModel.ToolboxItem(false)]
    // 若要允许使用 ASP.NET AJAX 从脚本中调用此 Web 服务，请取消注释以下行。 
    // [System.Web.Script.Services.ScriptService]
    public class SecretaryService : WS.Helper.BaseServiceHelper
    {
        [SoapHeader("MyHeader")]
        [WebMethod(Description = @"<b><i>秘书根据分组获取抽签信息</i></b>")]
        public string GetScoreQuery_Sec(string strGroupNO, string strExamRoomID)
        {
            return ServiceSecretary.GetScoreQuery_Sec(strGroupNO, strExamRoomID).ToJson();
        }
         
        [SoapHeader("MyHeader")]
        [WebMethod(Description = @"<b><i>秘书根据分组获取正在考试信息</i></b>")]
        public string GetScoreQuery_Sec_KS(string strGroupNo, string strExamRoomID)
        {
            return ServiceSecretary.GetScoreQuery_Sec_KS(strGroupNo, strExamRoomID).ToJson();
        }

        [SoapHeader("MyHeader")]
        [WebMethod(Description = @"<b><i>获取老师打分</i></b>")]
        public string GetTeacherNoDF(string strGroupNo, string strExamRoomID)
        {
            return ServiceSecretary.GetTeacherNoDF(strGroupNo, strExamRoomID).ToJson();
        }

        [SoapHeader("MyHeader")]
        [WebMethod(Description = @"<b><i>保存打分</i></b>")]
        public string SaveSecExaming(string strNum, string strGroupNo, string strExamRoomID, string strExamRoomName)
        {
            return ServiceSecretary.SaveSecExaming(strNum, strGroupNo, strExamRoomID, strExamRoomName).ToJson();
        }



        /// <summary>
        /// 通过考场和组来计算平均分
        /// </summary>
        /// <param name="strAGT_ID"></param>
        /// <param name="strExamRoomID"></param>
        /// <returns></returns>
        [SoapHeader("MyHeader")]
        [WebMethod(Description = @"<b><i>通过考场和组来计算平均分</i></b>")]
        public string SaveCalculationAvgPoints(string strAGT_ID, string strExamRoomID)
        {
            return ServiceSecretary.SaveCalculationAvgPoints(strAGT_ID, strExamRoomID).ToJson();
        }
    }
}
